package com.atguigu.guli.edu.controller.api;

import com.atguigu.common_utils.utils.R;
import com.atguigu.guli.edu.entity.Subject;
import com.atguigu.guli.edu.service.EduSubjectService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;


/**
 * 课程科目
 *
 * @author chenshun
 * @email sunlightcs@gmail.com
 * @date 2021-01-19 10:59:18
 */
@Api(tags = "课程分类模块")

@RestController
@RequestMapping("/api/edu/subject")
public class ApiEduSubjectController {
    @Autowired
    private EduSubjectService eduSubjectService;

    @GetMapping("/select/categroy")
    public R getCategorg(){
        List<Subject> subjects = eduSubjectService.selectLevel();
        return R.ok().put("data",subjects);
    }


}
